Skip to content

pr: [Nightly Fix] - Bug - Fix Dashboard Widget Permission Check Typo#53

Open
jewel-claw wants to merge 1 commit intomasterfrom
nightly-fix/dashboard-widget-permission-typo
Open

pr: [Nightly Fix] - Bug - Fix Dashboard Widget Permission Check Typo#53
jewel-claw wants to merge 1 commit intomasterfrom
nightly-fix/dashboard-widget-permission-typo

Conversation

@jewel-claw
Copy link
Copy Markdown

Summary

Typo: 'get_sumissions''get_submissions' in DashboardWidgetModule::addWidget().

AccessControl::hasEndPointPermission() looks up the endpoint name against the registered permission map for the 'submissions' group. Because 'get_sumissions' (missing 'b') does not exist in that map, the method always returned false for non-admin users.

Effect: Any user with wpf_can_view_all_entries or related submission permissions would never see the WPPayForm dashboard widget, even though they should. Admins were unaffected because they have grand access via hasGrandAccess().

'get_sumissions' → 'get_submissions'

The typo caused AccessControl::hasEndPointPermission() to always return false
for the 'submissions' group since 'get_sumissions' is not a registered endpoint.
Non-admin users with wpf submission permissions were never shown the dashboard
widget even when they had the correct capability.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant